package com.mathdroid.model.buffs;

import com.mathdroid.model.enums.EBuffType;

/**
 * This utility class creates a new template of buffs. Those buffs are
 * by default disabled/inactive.
 */
public final class BuffFactory { 
	
	/**
	 * Hidden default constructor.
	 */
	private BuffFactory() { }
	
	/**
	 * Get a new buff template with all buffs disabled.
	 * @return New unbuffed template.
	 */
	public static BuffTemplate getNewUnbuffedTemplate() {
		
		final BuffTemplate t = new BuffTemplate("Unbuffed");
		
		final String suffix = " If the target is a party member, "
				+ "all other party members are also affected.";
		
		t.add(new GroupBuffDebuff("Force Might / Unnatural Might", "buff01", 
				"Increases the target's melee, ranged, Force and tech "
				+ "bonus damage and healing by 5% for 60 minutes." + suffix,
				EBuffType.BENEFICIAL_GROUP_BUFF));
		
		t.add(new GroupBuffDebuff("Force Valor / Mark of Power", "buff02", 
				"Increases the target's Strength, Aim, Willpower and "
				+ "Cunning by 5% and internal and elemental damage "
				+ "reduction by 10% for 60 minutes." + suffix,
				EBuffType.BENEFICIAL_GROUP_BUFF));
		
		t.add(new GroupBuffDebuff("Fortification / Hunter's Boon", "buff03", 
				"Increases the target's Endurance by 5% for 60 minutes." 
				+ suffix,
				EBuffType.BENEFICIAL_GROUP_BUFF));
		
		t.add(new GroupBuffDebuff("Lucky Shots / Coordination", "buff04", 
				"Increases the target's critical hit chance by 5% "
				+ "for 60 minutes." + suffix,
				EBuffType.BENEFICIAL_GROUP_BUFF));
		
		t.add(new GroupBuffDebuff(
				"Supercharged Gas", 
				"buff05", 
				"NYI Damage Reduction Buff",
				EBuffType.BENEFICIAL_BUFF));
		
		t.add(new GroupBuffDebuff(
				"Reconstruct / Reactive Armor", 
				"buff06", 
				"NYI Armor Buff",
				EBuffType.BENEFICIAL_BUFF));
		
		t.add(new GroupBuffDebuff(
				"Coordination", 
				"buff07", 
				"NYI Critical Hit Chance Buff",
				EBuffType.BENEFICIAL_BUFF));
		
		t.add(new GroupBuffDebuff(
				"Discharge / Oil Slick / Quake", 
				"buff08", 
				"NYI Accuracy Debuff",
				EBuffType.BENEFICIAL_DEBUFF));
		
		t.add(new GroupBuffDebuff(
				"Sundering Assault / Tracer Missile / Shatter Shot", 
				"buff09", 
				"NYI Armor Debuff",
				EBuffType.BENEFICIAL_DEBUFF));
		
		t.add(new GroupBuffDebuff(
				"Combust / Wither", 
				"buff10", 
				"NYI Damage Reduction Debuff",
				EBuffType.BENEFICIAL_DEBUFF));
		
		return t;
	}

	/**
	 * Get a new buff template with all buffs enabled.
	 * @return New fully buffed template.
	 */
	public static BuffTemplate getNewFullyBuffedTemplate() {
		final BuffTemplate t = BuffFactory.getNewUnbuffedTemplate();
		
		t.setName("Fully buffed");
		
		for (GroupBuffDebuff gb : t) {
			gb.setActive(true);
		}
		
		return t;
	}
}
